FortiGate 50EにOpenWRTを入れtincをセットアップする
上記の記事を参考に進める
詰まったところ
ipアドレスの設定
家のルータに繋ぐのはLAN1の方
firewall
wanからssh
イメージの取得
以下のページからopenwrt-mvebu-cortexa9-fortinet_fg-50e-initramfs-kernel.binをダウンロードする
TFTPサーバの起動
openwrt-mvebu-cortexa9-fortinet_fg-50e-initramfs-kernel.binをカレントディレクトリに置いたうえで、以下のコマンドを実行する
code:sh
docker run --rm -p 69:69/udp -v "$(pwd)"/openwrt-mvebu-cortexa9-fortinet_fg-50e-initramfs-kernel.bin:/tftpboot/image.out:ro jumanjiman/tftp-hpa
メモ
tftp-hpaはDebianプロジェクト推奨のTFTPサーバらしいので、割と安心して使える
シリアルコンソールへの接続
電源を切る
コンソールケーブルをCONSOLEポートに挿す
CISCOのコンソールケーブルと同じものが使える
以下のコマンドを実行する
code:sh
screen /dev/ttyUSB0
デバイス名はコンソールケーブルや環境によって違うことがある
電源をいれる
Please wait for OS to boot, or press any key to display configuration menu.. と出てきたらすかさずEnterキーを押す
ブートメニュー
code:txt
FortiGate-50E (17:37-01.31.2017)
Ver:05000016
Serial number: FGT50E3U17043203
CPU(00): 1600MHz
Total RAM: 2GB
Initializing boot device...
Initializing MAC... egiga1
Please wait for OS to boot, or press any key to display configuration menu..
C: Configure TFTP parameters. R: Review TFTP parameters. T: Initiate TFTP firmware transfer. B: Boot with backup firmware and set as default. Q: Quit menu and continue to boot. H: Display this list of options. Enter C,R,T,F,I,B,Q,or H:
Rを押すと現在のTFTPサーバの設定が確認できる
Review TFTP parameters
code:txt
Image download port: WAN1
DHCP status: Disabled
Local VLAN ID: <NULL>
Local IP address: 192.168.1.188
Local subnet mask: 255.255.255.0
Local gateway: 192.168.1.254
TFTP server IP address: 192.168.1.168
Firmware file name: image.out
Enter C,R,T,F,I,B,Q,or H:
Configure TFTP parameters
code:txt
P: Set firmware download port. S: Set local subnet mask. T: Set remote TFTP server IP address. F: Set firmware file name. E: Reset TFTP parameters to factory defaults. R: Review TFTP parameters. N: Diagnose networking(ping). H: Display this list of options. Enter P,D,I,S,G,V,T,F,E,R,N,Q,or H:
N を押すとpingなどがおこなえる